package com.sj.purchase.modules.cost.domain.imei;

import javax.persistence.*;
import java.util.Date;

/**
 * 串码
 * Created by icodebug on 17-7-14.
 */
@Entity
public class Imei {

    @Id
    private ImeiId id;

    private String sku;

    @Temporal(TemporalType.TIMESTAMP)
    private Date createDate;

    @Enumerated(EnumType.STRING)
    private ImeiType imeiType;

    public ImeiId getId() {
        return id;
    }

    public void setId(ImeiId id) {
        this.id = id;
    }

    public String getSku() {
        return sku;
    }

    public void setSku(String sku) {
        this.sku = sku;
    }

    public Date getCreateDate() {
        return createDate;
    }

    public void setCreateDate(Date createDate) {
        this.createDate = createDate;
    }

    public ImeiType getImeiType() {
        return imeiType;
    }

    public void setImeiType(ImeiType imeiType) {
        this.imeiType = imeiType;
    }

    public enum ImeiType {
        IN,OUT
    }

    @Override
    public String toString() {
        return "Imei{" +
                "id=" + id +
                ", sku='" + sku + '\'' +
                ", createDate=" + createDate +
                ", imeiType=" + imeiType +
                '}';
    }
}
